<template>
    <div>
        <el-card v-for="item in cases" :key="item.id">
            <el-descriptions class="margin-top" :title="'第'+item.episode+'次病例信息'" 
            :column="3"  border>
            <el-descriptions-item>
                <template slot="label">
                    病史
                </template>
                {{item.patientHistory}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    体温
                </template>
                {{item.temperature}}℃
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    呼吸频率
                </template>
                {{item.rr }}次/分钟
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    体重
                </template>
                {{item.weight}}KG
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    症状表现
                </template>
                {{item.symptoms}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    CT结果
                </template>
                {{item.ct}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    核酸结果
                </template>
                {{item.pcr}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    诊断结果
                </template>
                {{item.diagnosis}}
            </el-descriptions-item>
            <el-descriptions-item >
                <template slot="label">
                    治疗措施
                </template>
                {{item.treatment}}
            </el-descriptions-item>
            <el-descriptions-item >
                <template slot="label">
                    开具药物
                </template>
                {{item.medicals}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    治疗结果
                </template>
                {{item.outcome}}
            </el-descriptions-item>
            <el-descriptions-item>
                <template slot="label">
                    创建时间
                </template>
                {{item.createtime}}
            </el-descriptions-item>
        </el-descriptions>
        </el-card>
    </div>
</template>

<script>
import {getCasesByToken} from "../../../api/cases"
export default {
    data() {
        return {
            cases:[]
        };
    },

    mounted() {
        this.getCasesByToken()
    },

    methods: {
        async getCasesByToken(){
            await getCasesByToken().then(resp=>{
                if(resp.code==200){
                    this.cases = resp.data
                }
            })
        }
    },
};
</script>

<style scoped>

</style>